<template>
  <view class="map-container" @tap="navigateToIndex1">
   

    <!-- 地图区域 -->
    <view class="map-wrapper">
      <view class="map-border">
      
        <view class="top-border">
          <text class="border-mark-left">2px</text>
          <text class="border-mark-center">55px</text>
          <text class="border-mark-right">2px</text>
        </view>
        
        <!-- 地图内容 -->
        <view class="map-content">
          <image src="/static/bg10.png" mode="aspectFit" class="map-image"></image>
        </view>
       
        <view class="bottom-border">
          <text class="border-mark">2px</text>
        </view>
      </view>
    </view>
  </view>
</template>

<script>
export default {
  data() {
    return {
  
    }
  },
  methods: {
    // 点击页面任意位置跳转到index1.vue
    navigateToIndex1() {
      uni.redirectTo({
        url: '/pages/index/gift'
      })
    }
  }
}
</script>

<style scoped>
.map-container {
  width: 100%;
  height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: #f5f5f5;
}

.header {
  width: 100%;
  padding: 20rpx 0;
  background-color: #fff;
  border-bottom: 2px solid #e0e0e0;
  position: relative;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 30rpx;
}

.header-title {
  font-size: 36rpx;
  color: #333;
  font-weight: 500;
}

.header-right {
  position: relative;
}

.map-wrapper {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 30rpx;
}

.map-border {
  position: relative;
  width: 100%;
  max-width: 800rpx;
  border: 2px solid #e0e0e0;
  border-radius: 10rpx;
  overflow: hidden;
}

.top-border {
  position: absolute;
  top: -30rpx;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  padding: 0 30rpx;
}

.border-mark-left {
  position: relative;
  left: 0;
  background-color: #fff;
  padding: 0 10rpx;
  font-size: 24rpx;
  color: #666;
}

.border-mark-center {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  background-color: #fff;
  padding: 0 10rpx;
  font-size: 24rpx;
  color: #666;
}

.border-mark-right {
  position: relative;
  right: 0;
  background-color: #fff;
  padding: 0 10rpx;
  font-size: 24rpx;
  color: #666;
}

.map-content {
  width: 100%;
  padding-top: 120%; /* 保持适当的宽高比 */
  position: relative;
  background-color: #f5f5f5;
}

.map-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.bottom-border {
  position: absolute;
  bottom: -30rpx;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
}

.border-mark {
  background-color: #fff;
  padding: 0 10rpx;
  font-size: 24rpx;
  color: #666;
}
</style>